package com.ys.enume.storage;

/**
 * @Author: fxz
 * @CreateTime: 2025-03-13
 * @Description: 物流服务商api枚举
 * @Version: 1.0
 */
public class TccLogisticsApiLogEnum {
    public enum TypeNo {
        IP("请求网址", "http://8.134.39.115:8000","ip"),
        GETPRICE("正式费用查询接口", "/api/v1/common/getprice","getprice"),
        GETORDER("订货详情获取", "/api/v1/common/getorder","getorder"),
        CANCELORDER("订单取消", "/api/v1/common/cancelorder","cancelorder"),
        PRINT("标签获取打印", "/api/v1/common/print","print"),
        TRACKING("运单轨迹查询", "/api/v1/common/tracking","tracking"),
        CREATEORDER("创建订单", "/api/v1/common/createorder","createorder"),
        GETFILE("获取文件", "/api/v1/common/getfile","getfile"),
        ;

        public String name;
        public String value;
        public String key;

        private TypeNo(String name, String value, String key) {
            this.name = name;
            this.value = value;
            this.key = key;
        }

        public static String getName(String value) {
            for (TypeNo e : TypeNo.values()) {
                if (e.value == value) {
                    return e.name;
                }
            }

            return "";
        }


        public static String getKey(String value) {
            for (TypeNo e : TypeNo.values()) {
                if (e.value == value) {
                    return e.key;
                }
            }

            return "";
        }
    }

    public enum TypeService {
        KYT("快驿通", 0),
        ;

        public String name;
        public Integer value;

        private TypeService(String name, Integer value) {
            this.name = name;
            this.value = value;
        }

        public static String getName(Integer value) {
            for (TypeService e : TypeService.values()) {
                if (e.value == value) {
                    return e.name;
                }
            }

            return "";
        }
    }
}
